# Maintainer: Sergej Pupykin <pupykin.s+arch@gmail.com>
# Contributor: Sergej Pupykin <pupykin.s+aur@gmail.com>

pkgname=perl-email-address
pkgver=1.913
pkgrel=2
pkgdesc="RFC 2822 Address Parsing and Creation "
arch=('any')
url="https://search.cpan.org/dist/Email-Address"
license=('GPL' 'PerlArtistic')
depends=('perl')
options=('!emptydirs')
source=("https://search.cpan.org/CPAN/authors/id/R/RJ/RJBS/Email-Address-$pkgver.tar.gz")
sha256sums=('6afb541f6df6b535ccf7642d361ae18d7a95a3f93ace1bc5373f64c2410ca5af')

build() {
  cd  "$srcdir"/Email-Address-$pkgver
  PERL_MM_USE_DEFAULT=1 perl Makefile.PL INSTALLDIRS=vendor
  make
}

package() {
  cd  "$srcdir"/Email-Address-$pkgver
  make install DESTDIR="$pkgdir"
  find "$pkgdir" -name '.packlist' -delete
  find "$pkgdir" -name '*.pod' -delete
}
